package svc

import (
	"hosp/api/internal/config"
	"hosp/hosprpc/hosprpcclient"

	"github.com/zeromicro/go-zero/zrpc"
)

type ServiceContext struct {
	Config  config.Config
	HospRpc hosprpcclient.Hosprpc
}

func NewServiceContext(c config.Config) *ServiceContext {
	return &ServiceContext{
		Config:  c,
		HospRpc: hosprpcclient.NewHosprpc(zrpc.MustNewClient(c.HospRpc)),
	}
}
